function validate(){
	var subgr= document.getElementById('sltSubgr');
	var rel= document.getElementById('sltRel');
	var com= document.getElementById('sltComby');
	var cdy= document.getElementById('txtCdy');
	var feed=document.getElementById('txtFeed');
	
	if(madeSelection(subgr, "Select the Subject Code")){
		if(madeSelection(rel, "Select the Related Option")){ 
	          if(madeSelection(com, "Select the Commented Option")){ 
			         if(notEmpty(cdy, "Select the date")){ 
					       	if(notEmpty(feed, "Feedback cannot be empty")){
									
							                   loadXMLDoc()
	                                                                   
						   }
					 return false;
					 }
			  return false;
			  }
		    return false;
			}
		return false;
		}
	return false;
	}
	
	
	function loadXMLDoc()
{


if (window.XMLHttpRequest)
  {// code for IE7+, Firefox, Chrome, Opera, Safari
  xmlhttp=new XMLHttpRequest();
  }
else
  {// code for IE6, IE5
  xmlhttp=new ActiveXObject("Microsoft.XMLHTTP");
  }
xmlhttp.onreadystatechange=function()
  {
  if (xmlhttp.readyState==4 && xmlhttp.status==200)
    {
		
    document.getElementById("ajaxDiv").innerHTML=xmlhttp.responseText;
	document.getElementById("myForm").reset(); 
	
	
    }
  }

               var subgr= document.getElementById('sltSubgr').value;
	           var rel= document.getElementById('sltRel').value;
	           var com= document.getElementById('sltComby').value;
		       var cdy= document.getElementById('txtCdy').value;
	           var feed=document.getElementById('txtFeed').value;
	
	
	
	var queryString ="?subgr=" + subgr +"&rel="+rel+ "&com=" + com +"&cdy="+cdy+ "&feed=" + feed ;
	
	
xmlhttp.open("GET","../logic/add/feedback_add.php"+queryString ,true);
xmlhttp.send();
}
	
	
	
	
	
	
	
	
	
	function clearx()
{
	
	 document.getElementById("myForm").reset(); 
     document.getElementById("ajaxDiv").innerHTML="";
}